.TH rand.h 3 "19 Aug 2000" "gbdk-lib" \" -*- nroff -*-
.ad l
.nh
.SH NAME
rand.h \- Random generator using the linear congruential method. 
.SH SYNOPSIS
.br
.PP
.SS Functions

.in +1c
.ti -1c
.RI "void \fBinitrand\fR (\fBUINT16\fR seed) NONBANKED"
.br
.RI "\fIInitalise the random number generator.\fR"
.PP
.in +1c

.ti -1c
.RI "
\fBINT8\fR \fBrand\fR (void)"
.br
.RI "\fIReturns a random value.\fR"
.PP
.in +1c

.ti -1c
.RI "
\fBUINT16\fR \fBrandw\fR (void)"
.br
.RI "\fIReturns a random word.\fR"
.PP
.in +1c

.ti -1c
.RI "void \fBinitarand\fR (\fBUINT16\fR seed)"
.br
.RI "\fIRandom generator using the linear lagged additive method Note that '\fBinitarand\fR()' calls '\fBinitrand\fR()' with the same seed value, and uses '\fBrand\fR()' to initialize the random generator.\fR"
.PP
.in +1c

.ti -1c
.RI "
\fBINT8\fR \fBarand\fR (void)"
.br
.RI "\fIGenerates a random number using the linear lagged additive method.\fR"
.PP

.in -1c
.SH DETAILED DESCRIPTION
.PP 
Random generator using the linear congruential method.
.PP
\fBAuthor(s): \fR
.in +1c
Luc Van den Borre 
.SH FUNCTION DOCUMENTATION
.PP 
.SS void initrand (\fBUINT16\fR seed)
.PP
Initalise the random number generator.
.PP
seed needs to be different each time, else the same sequence will be generated. A good source is the DIV register. 
.SS void initarand (\fBUINT16\fR seed)
.PP
Random generator using the linear lagged additive method Note that '\fBinitarand\fR()' calls '\fBinitrand\fR()' with the same seed value, and uses '\fBrand\fR()' to initialize the random generator.
.PP
\fBAuthor(s): \fR
.in +1c
Luc Van den Borre 
.SH AUTHOR
.PP 
Generated automatically by Doxygen for gbdk-lib from the source code.